$schema: https://azuremlschemas.azureedge.net/latest/commandComponent.schema.json

name: jsonl_score_biosbias_json
version: 0.0.1pre1
display_name: JSONL Score BIOSBIAS JSON Component
type: command
description: |
  Takes a JSONL file of results from running the JSON extraction
  test on BIOSBIAS, and computes correct answers.
  Has a lot of hard coded knowledge
is_deterministic: true

inputs:
  input_dataset:
    type: uri_file
    optional: false
    description: Dataset containing JSONL input
  input_encoding:
    type: string
    optional: false
    default: utf-8-sig
    description: Encoding format of the input dataset
  response_key:
    type: string
    optional: false
    description: Which key contains the answer produced by the model


code: ./src/

command: >-
  python ./jsonl_score_biosbias_json.py
  --input_dataset ${{ inputs.input_dataset }}
  --input_encoding ${{ inputs.input_encoding }}
  --response_key ${{ inputs.response_key }}

environment:
  # Will be updated when component uploads
  image: azureml:promptbase_aml@latest